/*
 * Copyright (c) 2006, 2022, webrx.cn All rights reserved.
 *
 */
package cn.webrx;

/**
 * <p>Project: javase202202 - For4
 * <p>Powered by Lisi On 2022-06-01 14:32:29
 * <p>Created by IntelliJ IDEA
 *

 * @version 1.0
 * @since 17
 */
public class For4 {
    public static void main(String[] args) {
        //案例代码：计算1+2+3+...+100 = ?
        int temp = 0;
        for (int i = 1; i <= 100; i++) {
            temp += i;
        }
        System.out.printf("1+2+3+...+100=%d", temp);
    }
}
